#include<stdio.h>


//   a + aa + aaa + aaaa ....


int main()
{
    int a = 1;
    int n = 2;
    // 1 + 11 + 111 + 1111 + 11111 = ?
    int sum = 0;
    int value = 0;  //每次循环加的数值
    for(int i = 0; i < n; i++)   //循环加n个数
    {
        value = value * 10 + a;
        sum += value;
    }
    printf("%d\n",sum);

    return 0;
}